import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import adminlist from '../views/adminlist.vue'
import adminedit from '../views/adminedit.vue'
import adminidedit from '../views/adminidedit.vue'
import teafriendlist from '../views/teafriendlist.vue'
import teafriendedit from '../views/teafriendedit.vue'
import teafriendidedit from '../views/teafriendidedit.vue'
import tealist from '../views/tealist.vue'
import teaedit from '../views/teaedit.vue'
import teaidedit from '../views/teaidedit.vue'
import goodslist from '../views/goodslist.vue'
import goodsedit from '../views/goodsedit.vue'
import goodsidedit from '../views/goodsidedit.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView
  },
  {
    path: '/adminlist',
    component: adminlist
  },
  {
    path: '/adminedit',
    component: adminedit
  },
  {
    path: '/adminidedit',
    component: adminidedit
  },
  {
    path: '/teafriendlist',
    component: teafriendlist
  },
  {
    path: '/teafriendedit',
    component: teafriendedit
  },
  {
    path: '/teafriendidedit',
    component: teafriendidedit
  },
  {
    path: '/tealist',
    component: tealist
  },
  {
    path: '/teaedit',
    component: teaedit
  },
  {
    path: '/teaidedit',
    component: teaidedit
  },
  {
    path: '/goodslist',
    component: goodslist
  },
  {
    path: '/goodsedit',
    component: goodsedit
  },
  {
    path: '/goodsidedit',
    component: goodsidedit
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
